# imports python debugging tools for pyobjc
# basically stuff to dump stack traces

import sys
from Foundation import *

DEBUGGING = True

if DEBUGGING:
   NSLog("Importing Signals")
   from PyObjCTools import Signals
   Signals.dumpStackOnFatalSignal()
   NSLog("Imported Signals")
   NSLog("Importing debugging")
   from PyObjCTools import Debugging
   Debugging.installVerboseExceptionHandler()
   #Debugging.installExceptionHandler()
   NSLog("Imported debugging")
   NSLog("System version = %s" %sys.version)